/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package iteracon.stack;

import java.util.List;

/**
 *
 * @author martin
 */
public interface Stk<T> extends List<T>{
  /**
   * top element of stack
   * @return element
   */
  public T top();
  /**
   * remove top most element
   * being immutable, it return modified version
   * @return stack minus top element
   */
  public Stk<T> pop();
  /**
   * add new element to top
   * being immutable , it return modified version
   * @param t as type
   * @return new stack with added value
   */
  public Stk<T> push(final T t);
  /**
   * size of the stack
   * @return size as int
   */
  public int size();
}
